/**
 * Generate time : 2011-06-27 5:55:00
 * Version : 1.0.1.V20070717
 */
package com.baosight.sczx.zm.cc.domain;

import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;

/**
 * ZMCC5examinerateSetting
 * 
 */
public class ZMCC5examinerateSetting extends DaoEPBase {

	private String fdKeyId = " "; /* 主键 */
	private String fdOrgId = " "; /* 组织机构ID */
	private String fdRateId = " "; /* 权重ID */

	/**
	 * initialize the metadata
	 */
	public void initMetaData() {
		EiColumn eiColumn;

		eiColumn = new EiColumn("fdKeyId");
		eiColumn.setPrimaryKey(true);
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("主键");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdOrgId");
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("组织机构ID");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdRateId");
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("权重ID");
		eiMetadata.addMeta(eiColumn);

	}

	/**
	 * the constructor
	 */
	public ZMCC5examinerateSetting() {
		initMetaData();
	}

	/**
	 * get the fdKeyId - 主键
	 * 
	 * @return the fdKeyId
	 */
	public String getFdKeyId() {
		return this.fdKeyId;
	}

	/**
	 * set the fdKeyId - 主键
	 */
	public void setFdKeyId(String fdKeyId) {
		this.fdKeyId = fdKeyId;
	}

	/**
	 * get the fdOrgId - 组织机构ID
	 * 
	 * @return the fdOrgId
	 */
	public String getFdOrgId() {
		return this.fdOrgId;
	}

	/**
	 * set the fdOrgId - 组织机构ID
	 */
	public void setFdOrgId(String fdOrgId) {
		this.fdOrgId = fdOrgId;
	}

	/**
	 * get the fdRateId - 权重ID
	 * 
	 * @return the fdRateId
	 */
	public String getFdRateId() {
		return this.fdRateId;
	}

	/**
	 * set the fdRateId - 权重ID
	 */
	public void setFdRateId(String fdRateId) {
		this.fdRateId = fdRateId;
	}

	/**
	 * get the value from Map
	 */
	@SuppressWarnings("rawtypes")
	public void fromMap(Map map) {

		setFdKeyId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdKeyId")), fdKeyId));
		setFdOrgId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdOrgId")), fdOrgId));
		setFdRateId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdRateId")), fdRateId));
	}

	/**
	 * set the value to Map
	 */
	@SuppressWarnings({ "rawtypes", "unchecked" })
	public Map toMap() {

		Map map = new HashMap();
		map.put("fdKeyId", StringUtils.toString(fdKeyId, eiMetadata.getMeta("fdKeyId")));
		map.put("fdOrgId", StringUtils.toString(fdOrgId, eiMetadata.getMeta("fdOrgId")));
		map.put("fdRateId", StringUtils.toString(fdRateId, eiMetadata.getMeta("fdRateId")));

		return map;

	}
}